FROM python:3.11.9-slim-bullseye

WORKDIR /usr/src/stock_market/
RUN sed -i s/deb.debian.org/mirrors.ustc.edu.cn/g /etc/apt/sources.list
RUN rm -f /etc/localtime
RUN cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
RUN echo "Asia/Shanghai" > /etc/timezone
COPY . .
RUN python3 -m pip install --upgrade pip -i https://mirrors.aliyun.com/pypi/simple
RUN pip3 install -r requirements.txt -i https://mirrors.aliyun.com/pypi/simple
CMD python main.py
